<template>
  <div id="FormDialog">
    <PeopleSelect
      ref="peopleSelect"
      :type="'multiple'"
      :isCheck="true"
      :open="peopleOpen"
      @cancel="peopleOpen = false"
      @submit="submitPeople"
    ></PeopleSelect>
    <DepartmentDialog
      ref="peopleSelect"
      :type="'multiple'"
      :isCheck="true"
      :open="peopleOpen1"
      @cancel="peopleOpen1 = false"
      @submit="submitPeople1"
    ></DepartmentDialog>
    <el-row>
      <el-col :span="24" class="margin_col">
        <div class="always_handerOne">
          <div class="always_hander"></div>
          <div class="always_title">
            {{ title ? `${title}` : "项目查评" }}
          </div>
        </div>
      </el-col>
      <el-col :span="24" class="margin_col">
        <div class="always_handerOne1">
          <el-collapse v-model="activeNames">
            <el-collapse-item name="0">
              <template slot="title">
                <div class="always_title1">
                  <div></div>
                  基本信息
                </div>
              </template>
              <div class="container">
                <h2 style="margin-left: 120px; margin-right: 18px;  font-size: 15px; color: #303133; line-height: 40px; " >所属科目：
                <span>{{subject}}</span>
                </h2>
              </div>
              <el-form
                :model="formData"
                ref="vForm"
                :rules="rules"
                label-position="center"
                label-width="120px"
                :size="medium"
                style="display: flex; justify-content: flex-start"
              >
                <el-form-item label="项目名称" prop="evaluationElements">
                  <el-input
                    v-model="formData.evaluationElements"
                    :disabled="true"
                    type="text"
                    clearable
                    :size="medium"
                    placeholder="请输入内容"
                  ></el-input>
                </el-form-item>
                <el-form-item label="评审人" prop="examiner">
                  <el-input
                    v-model="formData.examiner"
                    :disabled="true"
                    type="text"
                    clearable
                    :size="medium"
                    placeholder="请输入评审人"
                  ></el-input>
                </el-form-item>
                <el-form-item label="受评单位" prop="evaluateObject">
                  <el-select
                    :disabled="true"
                    v-model="formData.evaluateObject"
                    class="full-width-input"
                    clearable
                    :size="medium"
                  >
                    <el-option
                      v-for="option in deptsOptions"
                      :key="option.value"
                      :label="option.label"
                      :value="option.value"
                    ></el-option>
                  </el-select>
                </el-form-item>
                <el-form-item label="标准分" prop="standardScore">
                  <el-input
                    v-model="formData.standardScore"
                    :disabled="true"
                    type="text"
                    clearable
                    :size="medium"
                    placeholder="请输入内容"
                  ></el-input>
                </el-form-item>
                <el-form-item label="状态" prop="reviewStatus">
                  <el-input
                    v-model="formData.reviewStatus"
                    type="text"
                    clearable
                    :size="medium"
                    :disabled="true"
                    placeholder="请输入内容"
                  ></el-input>
                </el-form-item>
                <el-form-item
                  label="评审事件"
                  prop="reviewEvents"
                  class="required"
                >
                  <el-input
                    v-model="formData.reviewEvents"
                    :disabled="true"
                    type="text"
                    clearable
                    :size="medium"
                    placeholder="请输入内容"
                  ></el-input>
                </el-form-item>
                <!-- <el-form-item> -->
                <!-- v-if="gist" -->
                <button
                  type="button"
                  style="
                    width: 36px;
                    height: 96px;
                    position: absolute;
                    right: 76px;
                    writing-mode: vertical-lr;
                    margin-left: 10px;
                    line-height: 20px;
                    padding-right: 24px;
                    padding-left: 12px;
                    background-color: #007efc;
                    border: none;
                    border-radius: 4px;
                    color: #fff;
                  "
                  @click="
                    switchShowDrawer(formData.evaluationElementsId);
                    return false;
                  "
                >
                  以往查评
                </button>
                <!-- </el-form-item> -->
                <!--                <div></div>-->
                <el-container style="width: 90%">
                  <el-container>
                    <el-header class="el-header">
                      <el-form-item
                        style="width: 100%"
                        label="是否适用"
                        prop="isApply"
                      >
                        <el-checkbox-group
                          v-model="formData.isApply"
                          @change="setMealSelect"
                        >
                          <el-checkbox-button
                            class="ces"
                            v-for="(item, index) in suit"
                            :label="item.name"
                            :key="index"
                            :disabled="isRadioGroupDisabled"
                          >{{ item.name }}
                          </el-checkbox-button
                          >
                        </el-checkbox-group>
                        <!-- <el-radio-group
                          v-model="formData.isApply"
                          :disabled="isRadioGroupDisabled"
                          class="el-radio-group"
                        >
                          <el-radio label="0" class="styleCentre"
                          >适用</el-radio
                          >

                          <el-radio label="2" class="styleCentre"
                          >不适用</el-radio
                          >
                          <el-radio label="1" class="styleCentre"
                          >不参与</el-radio
                          >
                        </el-radio-group> -->
                      </el-form-item>
                    </el-header>
                    <el-main class="el-header">
                      <el-form-item
                        style="width: 100%"
                        label="是否存在问题"
                        prop="isProblem"
                        v-if="flagNew"
                      >
                        <el-checkbox-group
                          v-model="formData.isProblem"
                          @change="isProblemChange(formData.isProblem)"
                        >
                          <el-checkbox-button
                            class="ces"
                            v-for="(item, index) in isproblem"
                            :label="item.name"
                            :key="index"
                            :disabled="isIsProblem"
                            ref="abc1"
                          >{{ item.name }}
                          </el-checkbox-button
                          >
                          <!--

style="width: 33.2%"
                           -->
                        </el-checkbox-group>
                        <!-- <el-radio-group
                          v-model="formData.isProblem"
                          @change="isProblemChange(formData.isProblem)"
                          :disabled="isIsProblem"
                          class="el-radio-group"
                        >
                          <el-radio label="1" value="1" class="styleCentre"
                          >是</el-radio
                          >
                          <el-radio label="0" value="0" class="styleCentre"
                          >否</el-radio
                          >
                        </el-radio-group> -->
                      </el-form-item>
                    </el-main>
                    <el-main class="el-header">
                      <el-form-item
                        style="width: 100%"
                        label="是否重大问题"
                        v-if="gist"
                        prop="isGreatProblem"
                      >
                        <el-checkbox-group
                          v-model="formData.isGreatProblem"
                          @change="isProblemBigChange"
                        >
                          <el-checkbox-button
                            class="ces"
                            v-for="(item, index) in isproblembig"
                            :label="item.name"
                            :key="index"
                            :disabled="isIsGreatProblem"
                          >{{ item.name }}
                          </el-checkbox-button
                          >
                          <!--
                            :style="{'--fill-color':item.color,'--fill-border':item.border}"
                           -->
                        </el-checkbox-group>
                        <!-- <el-radio-group
                          v-model="formData.isGreatProblem"
                          :disabled="isIsGreatProblem"
                        >
                          <el-radio label="1">是</el-radio>
                          <el-radio label="0">否</el-radio>
                        </el-radio-group> -->
                      </el-form-item>
                    </el-main>
                  </el-container>

                  <el-aside width="70%" class="style-Change">
                    <el-form-item
                      label="支撑材料"
                      prop="backingMaterial"
                      class="required"
                    >
                      <div>
                        <el-upload
                          multiple
                          v-model="formData.backingMaterial"
                          :action="uploadFileUrl"
                          :before-upload="handleBeforeUpload"
                          :file-list="fileList"
                          :on-error="handleUploadError"
                          :on-preview="handlePictureCardPreview"
                          :on-exceed="handleExceed"
                          :on-success="handleUploadSuccess"
                          :show-file-list="true"
                          :headers="headers"
                          class="upload-file-uploader"
                          list-type="picture-card"
                          :auto-upload="true"
                        >
                          <!-- :hidden="isBackingMaterial" -->
                          <i slot="default" class="el-icon-plus"></i>
                          <!-- v-if="fileHidden" -->
                          <div
                            slot="file"
                            slot-scope="{ file }"
                            style="width: 400%"
                          >
                            <img
                              class="el-upload-list__item-thumbnail"
                              :src="file.urlT"
                              alt=""
                            />

                            <span class="el-upload-list__item-actions">
                              <span
                                class="el-upload-list__item-preview"
                                v-if="true"
                                @click="handlePictureCardPreview(file)"
                              >
                                <i class="el-icon-zoom-in"></i>
                              </span>
                              <span
                                v-if="true"
                                class="el-upload-list__item-delete"
                                @click="handleDownload(file)"
                              >
                                <i class="el-icon-download"></i>
                              </span>
                              <span
                                v-if="true"
                                class="el-upload-list__item-delete"
                                @click="removeFile(index, file)"
                              >
                                <i class="el-icon-delete"></i>
                              </span>
                            </span>
                          </div>
                        </el-upload>
                        <div v-if="!fileShow" class="block_file_name">
                          <el-tooltip
                            v-for="(file, index) in newfileList"
                            :key="index"
                            style="display: inline-block"
                            class="item"
                            effect="dark"
                            :content="file.oldFileName"
                            placement="top-start"
                          >
                            <el-button
                              style="
                                overflow: hidden;
                                text-overflow: ellipsis;
                                white-space: nowrap;
                                width: 100px;
                              "
                            >{{ file.oldFileName }}
                            </el-button
                            >
                          </el-tooltip>
                          <!-- <span
                            v-for="(file, index) in newfileList"
                            :key="index"
                            style="display: inline-block"
                          >
                            {{ file.oldFileName }}
                          </span> -->
                        </div>
                      </div>
                      <!--                      <div v-if="!fileShow">-->
                    </el-form-item>
                  </el-aside>
                </el-container>

                <!--                </el-container>-->
                <el-container style="width: 90%" v-if="flagNew">
                  <el-form-item label="扣分" prop="deduct">
                    <el-input-number
                      v-model="formData.deduct"
                      @change="cliekDen(formData.deduct)"
                      :min="0"
                      :max="formData.standardScore"
                      :disabled="isDeduct"
                      label="描述文字"
                    ></el-input-number>
                    <!--                        v-if="gist"-->
                    <!-- <div class="block">
                    <el-slider
                      show-input
                      :disabled="isDeduct"
                      v-model="formData.deduct"
                      @change="cliekDen(formData.deduct)"
                      :min="0"
                      :max="bigPrice"
                    >
                    </el-slider>
                  </div> -->
                  </el-form-item>
                  <el-form-item
                    label="实得分"
                    prop="actualScore"
                    style="width: 30%"
                  >
                    <!--                  v-if="gist"-->
                    <el-input
                      v-model="actualScore"
                      :disabled="true"
                      type="text"
                      clearable
                      :size="medium"
                      placeholder="请输入内容"
                    ></el-input>
                  </el-form-item>
                  <el-form-item
                    label="评审对象"
                    prop="actualScore"
                    style="width: 30%"
                  >
                    <!--                  v-if="gist"-->
                    <el-input
                      v-model="formData.isposObject"
                      :disabled="isIspos"
                      type="text"
                      clearable
                      :size="medium"
                      placeholder="请输入内容"
                    ></el-input>
                  </el-form-item>
                </el-container>

                <!--                <div style="width: 50%"></div>-->
                <el-container style="width: 80%">
                  <!-- <el-form-item
                  label="实得分"
                  prop="actualScore"
                  style="width: 30%"
                >
                  <el-input
                    v-model="actualScore"
                    :disabled="true"
                    type="text"
                    clearable
                    :size="medium"
                    placeholder="请输入内容"
                  ></el-input>
                </el-form-item> -->
                </el-container>
                <el-form-item
                  label="查证情况"
                  prop="lookPapersCase"
                  class="sel-width"
                  v-if="flagNew"
                >
                  <el-input
                    :disabled="isLookPapersCase"
                    type="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.lookPapersCase"
                  >
                  </el-input>
                </el-form-item>
                <el-form-item
                  label="存在问题"
                  prop="problem"
                  class="sel-width"
                  v-if="gist"
                >
                  <el-input
                    :disabled="isPro"
                    type="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.problem"
                  >
                  </el-input>
                </el-form-item>
                <el-form-item
                  label="整改建议"
                  prop="rectifySuggest"
                  class="sel-width"
                  v-if="gist"
                >
                  <el-input
                    :disabled="isRectifySuggest"
                    type="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.rectifySuggest"
                  >
                  </el-input>
                </el-form-item>
                <el-form-item
                  label="扣分依据"
                  prop="deductPursuant"
                  class="sel-width"
                  v-if="gist"
                >
                  <el-input
                    :disabled="isDeductPursuant"
                    type="textarea"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.deductPursuant"
                  >
                  </el-input>
                </el-form-item>

                <el-form-item
                  label="评审标准"
                  prop="reviewStandard"
                  class="sel-width"
                >
                  <el-input
                    type="textarea"
                    :disabled="true"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.reviewStandard"
                  >
                  </el-input>
                </el-form-item>
                <el-form-item
                  label="评分标准"
                  prop="scoreStandard"
                  class="sel-width"
                >
                  <el-input
                    type="textarea"
                    :disabled="true"
                    :rows="4"
                    placeholder="请输入内容"
                    v-model="formData.scoreStandard"
                  >
                  </el-input>
                </el-form-item>
              </el-form>
            </el-collapse-item>
          </el-collapse>
        </div>
      </el-col>
      <el-col :span="24" class="margin_col" name="1">
        <div class="always_handerOne1">
          <custom-buttons
            @back="handleBack"
            @confirm="handleConfirm"
            :handleShow="handleShow"
          ></custom-buttons>
        </div>
      </el-col>
    </el-row>
    <el-drawer
      :withHeader="true"
      :title="checkForm.evaluationElements || ''"
      :visible.sync="showDrawer"
      :with-header="false"
    >
      <div style="padding: 0 30px; height: 93%">
        <el-form
          v-if="checkForm.evaluationElements"
          :model="checkForm"
          label-width="100px"
        >
          <el-form-item label="事件名称" prop="eventTitle">
            <el-select
              v-model="eventTitle"
              placeholder="请选择事件名称"
              style="width: 230px"
              clearable
              filterable
            >
              <!-- 使用 v-for 循环渲染选项 -->
              <el-option
                v-for="option in reviewEventsOptionsList"
                :key="option.review_events"
                :label="option.review_events"
                :value="option.review_events"
              ></el-option>
            </el-select>
          </el-form-item>
          <el-card class="box-card">
            <div slot="header" class="clearfix">
              <img class="cardImg" src="@/assets/images/verifg.png" alt=""/>
              <span class="titleStyle">查证情况</span>
              <el-button
                style="
                  float: right;
                  background-color: #e8f4ff;
                  color: #1890ff;
                  border: none;
                "
                type="primary"
                @click="onCopy(checkForm.lookPapersCase)"
              >复制
              </el-button
              >
            </div>
            <div class="text item">
              {{ checkForm.lookPapersCase }}
            </div>
          </el-card>
          <el-card class="box-card">
            <div slot="header" class="clearfix">
              <img class="cardImg" src="@/assets/images/problem.png" alt=""/>
              <span class="titleStyle">存在问题</span>
              <el-button
                style="
                  float: right;
                  background-color: #e8f4ff;
                  color: #1890ff;
                  border: none;
                "
                type="primary"
                @click="onCopy(checkForm.problem)"
              >复制
              </el-button
              >
            </div>
            <div class="text item">
              {{ checkForm.problem }}
            </div>
          </el-card>
          <el-card class="box-card">
            <div slot="header" class="clearfix">
              <img
                class="cardImg"
                src="@/assets/images/suggestion.png"
                alt=""
              />
              <span class="titleStyle">整改建议</span>
              <el-button
                style="
                  float: right;
                  background-color: #e8f4ff;
                  color: #1890ff;
                  border: none;
                "
                type="primary"
                @click="onCopy(checkForm.rectifySuggest)"
              >复制
              </el-button
              >
            </div>
            <div class="text item">
              {{ checkForm.rectifySuggest }}
            </div>
          </el-card>
          <el-card class="box-card">
            <div slot="header" class="clearfix">
              <img class="cardImg" src="@/assets/images/buckle.png" alt=""/>
              <span class="titleStyle">扣分依据</span>
              <el-button
                style="
                  float: right;
                  background-color: #e8f4ff;
                  color: #1890ff;
                  border: none;
                "
                type="primary"
                @click="onCopy(checkForm.deductPursuant)"
              >复制
              </el-button
              >
            </div>
            <div class="text item">
              {{ checkForm.deductPursuant }}
            </div>
          </el-card>
          <el-form-item label=" " class="sel-width">
            <div style="text-align: center; padding: 20px">
              <el-button @click="onSetInput" size="mini" type="primary">
                一键填入
              </el-button>
              <el-button @click="onRandomData" :loading="btLoading" size="mini">
                换一个
              </el-button>
            </div>
          </el-form-item>
          <!-- <div class="form-item">
            <el-form-item
              label="查证情况"
              prop="lookPapersCase"
              class="sel-width"
            >
              <div
                @click="onCopy(checkForm.lookPapersCase)"
                class="copy-text-box"
              >
                {{ checkForm.lookPapersCase }}
              </div>
            </el-form-item>
          </div> -->

          <!-- <div class="form-item">
            <el-form-item label="存在问题" prop="problem" class="sel-width">
              <div @click="onCopy(checkForm.problem)" class="copy-text-box">
                {{ checkForm.problem }}
              </div>
            </el-form-item>
          </div>

          <div class="form-item">
            <el-form-item
              label="整改建议"
              prop="rectifySuggest"
              class="sel-width"
            >
              <div
                @click="onCopy(checkForm.rectifySuggest)"
                class="copy-text-box"
              >
                {{ checkForm.rectifySuggest }}
              </div>
            </el-form-item>
          </div> -->

          <!-- <div class="form-item">
            <el-form-item
              label="扣分依据"
              prop="deductPursuant"
              class="sel-width"
            >
              <div
                @click="onCopy(checkForm.deductPursuant)"
                class="copy-text-box"
              >
                {{ checkForm.deductPursuant }}
              </div>
            </el-form-item>
          </div> -->
        </el-form>
        <el-empty v-else description="数据为空"></el-empty>
      </div>
    </el-drawer>
  </div>
</template>

<script>
const suitOptions = [
  {
    name: "适用",
    id: 0,
    color: "#ecf5ff",
    border: "#b3d8ff",
  },
  {
    name: "不适用",
    id: 2,
    color: "#fdf6ec",
    border: "#f5dab1",
  },
  {
    name: "不参与",
    id: 1,
    color: "#fdf6ec",
    border: "#f5dab1",
  },
];
const problemOptions = [
  {name: "是", id: 1, color: "#fdf6ec", border: "#f5dab1"},
  {name: "否", id: 0, color: "#ecf5ff", border: "#b3d8ff"},
];
const isproblembig1 = [
  {name: "是", id: 1, color: "#fdf6ec", border: "#f5dab1"},
  {name: "否", id: 0, color: "#ecf5ff", border: "#b3d8ff"},
];
import {
  listGroping,
  getGroping,
  delGroping,
  addGroping,
  updateGroping,
  listGropingByProject,
  getListSon,
  updateGropingById,
  dimSelect,
  getReviewEvents,
  getSubjectList,
} from "@/api/system/review/groping";
import {isSafeEva} from "@/api/system/review/evaluation";
import {
  getFilePath,
  delFileInfo,
  download,
  preview,
  viewPicture,
} from "@/api/system/sysFileInfo/fileInfo";
import CustomButtons from "@/components/CustomButton/CustomButton.vue";
import PeopleSelect from "../../../components/Selection/index.vue";
import DepartmentDialog from "../../../components/DepartmentDialog/index.vue";
import {getToken} from "@/utils/auth";
import {delOss} from "@/api/system/oss";
import {queryDept} from "@/api/system/review/event";

export default {
  components: {
    CustomButtons,
    PeopleSelect,
    DepartmentDialog,
  },
  props: {
    // 值
    value: [String, Object, Array],
    // 数量限制
    limit: {
      type: Number,
      default: 5,
    },
    // 大小限制(MB)
    fileSize: {
      type: Number,
      default: 200,
    },
    // 文件类型, 例如['png', 'jpg', 'jpeg']
    fileType: {
      type: Array,
      default: () => ["doc", "xls", "ppt", "txt", "pdf", "docx"],
    },
    // 是否显示提示
    isShowTip: {
      type: Boolean,
      default: true,
    },
  },
  data() {
    return {
      number: 0,
      uploadList: [],
      bigPrice: 0,
      dialogImageUrl: "",
      dialogVisible: false,
      baseUrl: process.env.VUE_APP_BASE_API,
      uploadFileUrl: process.env.VUE_APP_BASE_API + "/system/fileInfo/upload", // 上传文件服务器地址
      headers: {
        Authorization: "Bearer " + getToken(),
      },
      suit: suitOptions,
      isproblem: problemOptions,
      isproblembig: isproblembig1,
      imgurl: [],
      newfileList: [],
      isIspos: false,
      fileShow: true,
      actualScore: 0,
      fileList: [],
      medium: "medium",
      activeNames: ["0", "1", "2"],
      tableData: [],
      selectedRows: [],
      deptsOptions: [],
      gist: false,
      flagNew: false,
      handleShow: true,
      reviewEventsOptionsList: [],
      eventTitle: undefined,
      subject: '',
      formData: {
        id: undefined,
        refId: undefined,
        reviewEvents: undefined,
        groupName: undefined,
        groupLeader: undefined,
        groupLeaderCode: undefined,
        member: undefined,
        memberCode: undefined,
        creationDate: undefined,
        isDelete: undefined,
        taskAllocation: undefined,
        evaluationElements: undefined,
        standardScore: undefined,
        reviewStatus: undefined,
        reviewEventsId: undefined,
        evaluationElementsId: undefined,
        picture: undefined,
        examinerCode: undefined,
        examiner: undefined,
        isApply: [],
        lookWorkCase: undefined,
        evaluateCase: undefined,
        isInnovate: undefined,
        evaluateObject: undefined,
        backingMaterial: "",
        lookPapersCase: undefined,
        deduct: 0,
        isProblem: ["是"],
        problem: undefined,
        isGreatProblem: ["是"],
        rectifySuggest: undefined,
        scenePhoto: undefined,
        reviewStandard: undefined,
        scoreStandard: undefined,
        deptCode: undefined,
        deptName: undefined,
        responsibleCode: undefined,
        responsibleName: undefined,
        requireOkTime: undefined,
        okTime: undefined,
        requireSituation: undefined,
        okPhoto: undefined,
        deductPursuant: undefined,
        handleQuery: undefined,
        isposObject: undefined,
        // rectifySuggestHidden: false,
      },
      isBackingMaterial: false,
      isRadioGroupDisabled: false,
      isEvaluateObject: false,
      isIsProblem: false,
      isIsGreatProblem: false,
      isDeduct: false,
      isLookPapersCase: false,
      isDeductPursuant: false,
      isPro: false,
      isRectifySuggest: false,
      fileHidden: true,
      title: "",
      rules: {
        examiner: [
          {required: true, message: "检查人不能为空", trigger: "change"},
        ],
        isApply: [
          {required: true, message: "是否适用不能为空", trigger: "change"},
        ],
        evaluateObject: [
          {required: true, message: "查评对象不能为空", trigger: "change"},
        ],
        isProblem: [
          {
            required: true,
            message: "是否存在问题不能为空",
            trigger: "change",
          },
        ],
        isGreatProblem: [
          {
            required: true,
            message: "是否重大问题不能为空",
            trigger: "change",
          },
        ],
        deduct: [
          {required: true, message: "扣分不能为空", trigger: "change"},
        ],
        lookPapersCase: [
          {required: true, message: "查证情况不能为空", trigger: "change"},
        ],
        deductPursuant: [
          {required: true, message: "扣分依据不能为空", trigger: "change"},
        ],
        problem: [
          {required: true, message: "存在问题不能为空", trigger: "change"},
        ],
        rectifySuggest: [
          {required: true, message: "整改建议不能为空", trigger: "change"},
        ],
      },
      peopleOpen: false,
      peopleOpen1: false,
      FILEFileList: [],
      FILEUploadHeaders: {},
      FILEUploadData: {},
      btLoading: false,
      showDrawer: false,
      historyList: [],
      historyIndex: 0,
      listQueryParams: {},
    };
  },
  computed: {
    // 是否显示提示
    showTip() {
      return this.isShowTip && (this.fileType || this.fileSize);
    },
    checkForm() {
      if (this.historyList.length) {
        return this.historyList[this.historyIndex];
      }
      return {};
    },
  },
  watch: {
    newfileList: {
      handler(newVal, oldVal) {
        if (newVal.length > 0) {
          this.fileShow = false;
        } else {
          this.fileShow = true;
        }
      },
    },
  },
  created() {
    this.gist = true;
    this.flagNew = false;
    this.getTitle();
    this.handleRrdio();
    this.fetchReviewEventsData();
    this.listQueryParams = this.$route.query.queryParams;
    //是否适用
    switch (this.$route.query.row.isApply) {
      case "0":
        this.formData.isApply = ["适用"];
        this.flagNew = true;
        break;
      case "1":
        this.formData.isApply = ["不参与"];
        break;
      case "2":
        this.formData.isApply = ["不适用"];
        break;
      default:
        this.formData.isApply = [];
    }


    //是否存在问题
    if (this.formData.isProblem == undefined || this.formData.isProblem == null) {
      this.formData.isProblem = [];
    } else {
      "0" == this.$route.query.row.isProblem ? this.formData.isProblem = ["否"] : this.formData.isProblem = ["是"];
    }
    // this.formData.isProblem == undefined || this.formData.isProblem == null
    //   ? this.formData.isProblem = [] :
    //   "0" == this.$route.query.row.isProblem ? this.formData.isProblem = ["否"] : this.formData.isProblem = ["是"]


    //是否存在重大问题
    if (this.formData.isGreatProblem == undefined || this.formData.isGreatProblem == null) {
      this.formData.isGreatProblem = [];
    } else {
      "0" == this.$route.query.row.isGreatProblem ? this.formData.isGreatProblem = ["否"] : this.formData.isGreatProblem = ["是"];
    }
    //写法二
    // this.formData.isGreatProblem == undefined || this.formData.isGreatProblem == null
    //   ? this.formData.isGreatProblem = [] :
    //   "0" == this.$route.query.row.isGreatProblem ? this.formData.isGreatProblem = ["否"] : this.formData.isGreatProblem = ["是"]


    this.formData.backingMaterial = "";
    this.listQueryParams = this.$route.query.queryParams;
  },
  mounted() {
  },
  methods: {
    onCopy(text) {
      // 创建一个临时的textarea元素
      let textarea = document.createElement("textarea");
      // 设置textarea的值为要复制的文本
      textarea.value = text;
      // 将textarea元素添加到DOM中
      document.body.appendChild(textarea);
      // 选中textarea中的文本
      textarea.select();
      // 复制文本到剪贴板
      document.execCommand("copy");
      // 删除textarea元素
      document.body.removeChild(textarea);

      this.$message.success("文本复制成功");

      this.showDrawer = false;
    },
    switchShowDrawer(evaluationElementsId) {
      // event.preventDefult();
      if (!this.historyList.length) {
        // 传要素名称获取内容
        dimSelect(evaluationElementsId)
          .then((res) => {
            this.historyList = res;
          })
          .finally(() => {
          });
      }
      this.showDrawer = !this.showDrawer;
    },
    onRandomData() {
      this.btLoading = true;

      if (this.historyIndex < this.historyList.length - 1) {
        this.historyIndex++;
      } else {
        this.historyIndex = 0;
      }

      this.btLoading = false;
    },
    onSetInput() {
      let newObj = JSON.parse(JSON.stringify(this.checkForm));
      delete newObj.evaluationElements;

      this.formData = Object.assign(this.formData, newObj);
      this.formData.standardScore = Number(formData.standardScore);
      this.showDrawer = !this.showDrawer;
    },
    async getFile(id) {
      let ids = {
        ids:id
      }
      //调用后台接口,根据当前id查询所有的文件路径
      getFilePath(ids)
        .then(async (response) => {
          this.newfileList = response.data;
          for (const row of this.newfileList) {
            switch (row.ext) {
              case "pdf":
                this.dialogImageUrl = require("@/" + "img/pdf.png");
                break;
              case "txt":
                this.dialogImageUrl = require("@/" + "img/txt.png");
                break;
              case "doc" || "docx":
                this.dialogImageUrl = require("@/" + "img/word.png");
                break;
              case "MP4" || "MKV" || "RMVB":
                this.dialogImageUrl = require("@/" + "img/video.png");
                break;
              case "jpg":
                try {
                  const data = await viewPicture(row.id);
                  this.dialogImageUrl = window.URL.createObjectURL(
                    new Blob([data], {type: "image/jpeg"})
                  );
                } catch (error) {
                  console.log(error);
                }
                break;
              case "png" || "JPEG":
                try {
                  const data = await viewPicture(row.id);
                  this.dialogImageUrl = window.URL.createObjectURL(
                    new Blob([data], {type: "image/jpeg"})
                  );
                } catch (error) {
                  console.log(error);
                }
                break;
              default:
                this.dialogImageUrl = require("@/" + "img/1.png");
            }
            this.fileList.push({
              fileId: row.id,
              urlT: this.dialogImageUrl,
              url: row.fileUrl,
              name: row.oldFileName,
            });
          }
          // let data = new Blob([response], {
          //   type: "application/msword,charset=utf-8",
          // });
          // let fr = new FileReader();
          // fr.readAsArrayBuffer(data);
          // fr.addEventListener(
          //   "loadend",
          //   (e) => {
          //     let buffer = e.target.result;
          //     this.docxRender(buffer);
          //   },
          //   false
          // );
        })
        .finally(() => {
        });
    },
    handleRrdio() {
      if (this.formData.isProblem == 1) {
        this.gist = true;
      } else if (this.formData.isProblem == null) {
        this.gist = false;
      } else {
        this.gist = false;
      }
    },
    cliekDen(row) {
      // this.formData.standardScore = Number(formData.standardScore)

      this.actualScore = Number(this.formData.standardScore) - row;
      console.log(this.actualScore, row);
      // return
      if (
        this.actualScore == 0 ||
        isNaN(this.actualScore) ||
        this.actualScore == undefined
      ) {
        return (this.actualScore = 0);
      }
      if (row < this.formData.standardScore * 0.25) {
      } else if (row > this.formData.standardScore * 0.75) {
      } else {
      }
      // this.actualScore = this.actualScore - row;
    },
    getTitle() {
      debugger
      const {row, record, evalution} = this.$route.query;
      row.deduct = parseFloat(row.deduct);
      this.formData = row;
      this.getSubject(this.formData.evaluationElementsId);
      if (this.formData.standardScore != undefined || this.formData.standardScore != "") {
        this.formData.standardScore = Number(this.formData.standardScore);
        this.bigPrice = this.formData.standardScore;
      }
      if (isNaN(this.formData.deduct)) {
        this.formData.deduct = 0;
        this.actualScore = this.formData.standardScore;
      } else {
        this.actualScore = this.formData.standardScore - this.formData.deduct;
      }
      if (undefined != row.id) {
        this.getFile(row.id);
      }
      if (undefined == row.isProblem) {
        this.formData.examiner = this.$store.state.user.nikename;
      }
      if (record == 1 || evalution == 1) {
        this.handleShow = false;
        this.isBackingMaterial = true;
        this.isRadioGroupDisabled = true;
        this.isEvaluateObject = true;
        this.isIsProblem = true;
        this.isIsGreatProblem = true;
        this.isDeduct = true;
        this.isLookPapersCase = true;
        this.isDeductPursuant = true;
        this.isPro = true;
        this.isRectifySuggest = true;
        this.fileHidden = false;
        this.isShowTip = false;
        this.isIspos = true;
      }
      //调用后台看一下查评事件的类型是不是安评
      this.isSafeEva(row.id);
    },
    downloadLook(file) {
      let row = {};
      row.id = file.fileId;
      row.oldFileName = file.name;
      this.fileDownload(row);
    },
    // 是否适用
    setMealSelect(val) {
      // 截取数组的最后一位,并从新赋值
      this.formData.isApply = this.formData.isApply.slice(-1);
      switch (this.formData.isApply[0]){
        case  "不参与":
          this.formData.isProblem = [];
          this.formData.isGreatProblem = [];
          this.flagNew = false;
          this.gist = false;
          break;
        case "不适用":
          this.formData.isProblem = [];
          this.formData.isGreatProblem = [];
          this.flagNew = false;
          this.gist = false;
          break;
        default:
          this.flagNew = true;
      }
    },
    /** 文件下载操作 */
    fileDownload(row) {
      this.$modal.loading("下载中");
      preview(row.id).then((data) => {
        if (data != "") {
          // window.open(window.URL.createObjectURL(new Blob([data], {type: 'image/jpeg'})));
          return;
        }
      });
      download(row.id)
        .then((rew) => {
          this.$modal.closeLoading();
          // 创建临时的下载链接
          const url = window.URL.createObjectURL(rew);
          if (typeof window.chrome !== "undefined") {
            // chrome
            const link = document.createElement("a");
            link.href = url;
            //  row.oldFileName  文件名字
            link.download = row.oldFileName;
            link.click();
            // window.open(rew)
            window.URL.revokeObjectURL(link.href); // 释放资源
          } else if (typeof window.navigator.msSaveBlob !== "undefined") {
            // IE
            window.navigator.msSaveBlob(rew, row.oldFileName);
          } else {
            // Firefox
            const file = new File([rew], row.oldFileName, {
              type: "application/octet-stream",
            });
            window.open(URL.createObjectURL(file));
          }
        })
        .finally(() => {
        });
    },
    handleBack() {
      if (this.listQueryParams.params.endTime != undefined) {
        // 传递数据
        this.$router.push({
          path: "/review/localEvaluation/projectEvalutionList",
          query: {
            queryParams1: this.listQueryParams,
            time: this.listQueryParams.params,
          },
        });
      } else {
        // 传递数据
        this.$router.push({
          path: "/review/localEvaluation/projectEvalutionList",
          query: {
            queryParams: this.listQueryParams,
            time: undefined,
          },
        });
      }
      // this.$router.back();
      // 执行返回逻辑
    },
    open() {
      this.peopleOpen = true;
    },
    open2() {
      this.peopleOpen1 = true;
    },
    submitPeople1(peopleList) {
      if (peopleList.length != 1) {
        return this.$message.warning("请选择一个岗位");
      }
      this.formData.responsiblePost = peopleList[0].label;
      this.peopleOpen1 = false;
    },
    submitPeople(peopleList) {
      if (peopleList.length != 1) {
        return this.$message.warning("请选择一位人员");
      }
      this.formData.examiner = peopleList[0].userName;
      this.peopleOpen = false;
    },
    // 请求后台接口获取查评事件数据
    fetchReviewEventsData() {
      getReviewEvents()
        .then((response) => {
          this.reviewEventsOptionsList = response.data;
        })
        .finally(() => {
        });
    },
    //保存
    handleConfirm() {

      this.$refs["vForm"].validate((valid) => {
        if (valid) {
          if (this.formData.isApply[0] == "适用") {
            this.formData.isApply = 0;
            if (this.formData.isGreatProblem[0] == "是") {
              this.formData.isGreatProblem = 1;
            } else {
              this.formData.isGreatProblem = 0;
            }
            if (this.formData.isProblem[0] == "是") {
              this.formData.isProblem = 1;
            } else {
              this.formData.isProblem = 0;
              this.formData.problem = "";
              this.formData.rectifySuggest = "";
              this.formData.deductPursuant = "";
            }
          } else if (this.formData.isApply[0] == "不适用") {
            this.formData.isApply = 2;
            this.formData.deduct = 0;
            this.formData.lookPapersCase = "";
            this.formData.isProblem = "";
            this.formData.isGreatProblem = "";
          } else {
            this.formData.isApply = 1;
            this.formData.deduct = 0;
            this.formData.lookPapersCase = "";
            this.formData.isProblem = "";
            this.formData.isGreatProblem = "";
          }

          this.$modal.loading("保存中");
          if (this.formData.id !== undefined) {
            updateGropingById(this.formData)
              .then((response) => {
                this.$modal.msgSuccess("修改成功");
                if (this.listQueryParams.params.endTime != undefined) {
                  // 传递数据
                  this.$router.push({
                    path: "/review/localEvaluation/projectEvalutionList",
                    query: {
                      queryParams: this.listQueryParams,
                      time: this.listQueryParams.params,
                    },
                  });
                } else {
                  // 传递数据
                  this.$router.push({
                    path: "/review/localEvaluation/projectEvalutionList",
                    query: {
                      queryParams: this.listQueryParams,
                      time: undefined,
                    },
                  });
                }
                // this.$router.push(
                //   "/review/localEvaluation/projectEvalutionList"
                // );
              })
              .finally(() => {
                this.$modal.closeLoading();
              });
          } else {
            this.formData.refId = this.$route.query.id;
            this.formData.level = parseInt(this.$route.query.level) + 1;
            addGroping(this.formData)
              .then((response) => {
                this.$modal.msgSuccess("新增成功");
              })
              .finally(() => {
                // this.buttonLoading = false;
                this.$refs.vForm.resetFields(); // 重置表单数据
                this.$router.push(
                  "/review/localEvaluation/projectEvalutionList"
                );
                this.reset();
              });
          }
        }
      });
    },
    reset() {
      this.formData = {
        id: undefined,
        refId: undefined,
        reviewEvents: undefined,
        evaluationElements: undefined,
        examinerCode: undefined,
        examiner: undefined,
        isApply: undefined,
        lookWorkCase: undefined,
        evaluateCase: undefined,
        isInnovate: undefined,
        evaluateObject: undefined,
        backingMaterial: "",
        lookPapersCase: undefined,
        deduct: undefined,
        isProblem: undefined,
        problem: undefined,
        isGreatProblem: undefined,
        rectifySuggest: undefined,
        scenePhoto: undefined,
        reviewStatus: "未评审",
        reviewStandard: undefined,
        scoreStandard: undefined,
        isDelete: undefined,
        evaGroupId: undefined,
        deductPursuant: undefined,
        handleQuery: undefined,
      };
    },
    submitForm() {
    },
    queryDept() {
      //name 用于之后或许业务更改时用  备用
      let name = this.$store.state.user.name;
      queryDept(name).then((row) => {
        this.deptsOptions = [];
        row.forEach((item) => {
          this.deptsOptions.push({
            label: item.deptName,
            value: item.deptName,
          });
        });
      });
    },
    resetForm() {
      this.$refs["vForm"].resetFields();
    },
    // 判断是不是安全性评价 如果是那就会先评审标准和评分标准
    isSafeEva(value) {
      if (undefined != value) {
        //根据事件的id查看他的事件类型
        isSafeEva(value).then((res) => {
          // this.$set(this.formData, 'handleQuery', res.handleQuery);
          this.formData.reviewStandard = res.scoreStandard;
          this.formData.scoreStandard = res.handleQuery;
        });
      }
    },
    isProblemChange(value) {
      this.formData.isProblem = this.formData.isProblem.slice(-1);

      // 在这里执行与显示和隐藏相关的操作
      if (this.formData.isProblem[0] == "是") {
        // this.formData.rectifySuggestHidden = false;
        this.formData.isGreatProblem = [];
        this.gist = true;
      } else {
        // this.formData.rectifySuggestHidden = true;
        this.gist = false;
        this.formData.problem = "";
        this.formData.rectifySuggest = "";
        this.formData.deductPursuant = "";
        this.formData.isGreatProblem = [];
      }
    },
    isProblemBigChange() {
      this.formData.isGreatProblem = this.formData.isGreatProblem.slice(-1);
    },
    //文件上传
    handleBeforeUpload(file) {
      false;
      if (this.fileSize) {
        const isLt = file.size / 1024 / 1024 < this.fileSize;
        if (!isLt) {
          this.$modal.msgError(`上传文件大小不能超过 ${this.fileSize} MB!`);
          return false;
        }
      }
      this.$modal.loading("正在上传文件，请稍候...");
      this.number++;
      return true;
    },
    // 文件个数超出
    handleExceed() {
      this.$modal.msgError(`上传文件数量不能超过3个!`);
    },
    // 上传失败
    handleUploadError(err) {
      this.$modal.msgError("上传文件失败，请重试");
      this.$modal.closeLoading();
    },
    handlePictureCardPreview(file) {
      preview(file.fileId).then((data) => {
        if (data != "") {
          window.open(
            window.URL.createObjectURL(new Blob([data], {type: "image/jpeg"}))
          );
          return;
        }
      });
      this.dialogVisible = true;
    },
    handleDownload(file) {
      // window.open(file.url)
      let row = {};
      row.id = file.fileId;
      row.oldFileName = file.name;
      this.fileDownload(row);
    },
    handleRemove(s) {
    },
    test(res) {
      // debugger
      this.uploadList.push({
        name: res.data.oldFileName,
        url: res.data.fileUrl,
        fileId: res.data.id,
        urlT: this.dialogImageUrl,
      });
      this.uploadedSuccessfully();
    },
    // 上传成功回调
    handleUploadSuccess(res, file) {
      console.log(res, file);
      let suffix = res.data.fileName.split(".").pop();
      // debugger
      switch (suffix) {
        case "pdf":
          this.dialogImageUrl = require("@/" + "img/pdf.png");
          this.test(res);
          break;
        case "txt":
          this.dialogImageUrl = require("@/" + "img/txt.png");
          this.test(res);
          break;
        case "doc" || "docx":
          this.dialogImageUrl = require("@/" + "img/word.png");
          this.test(res);
          break;
        case "xlsx" || "xls":
          this.dialogImageUrl = require("@/" + "img/excel.png");
          this.test(res);
          break;
        case "MP4" || "MKV" || "RMVB":
          this.dialogImageUrl = require("@/" + "img/video.png");
          this.test(res);
          break;
        case "jpg":
          viewPicture(res.data.id).then((data) => {
            this.dialogImageUrl = window.URL.createObjectURL(
              new Blob([data], {type: "image/jpeg"})
            );
            this.test(res);
          });
          break;
        case "JPEG":
          viewPicture(res.data.id).then((data) => {
            this.dialogImageUrl = window.URL.createObjectURL(
              new Blob([data], {type: "image/jpeg"})
            );
            this.test(res);
          });
          break;
        case "png":
          viewPicture(res.data.id).then((data) => {
            this.dialogImageUrl = window.URL.createObjectURL(
              new Blob([data], {type: "image/jpeg"})
            );
            this.test(res);
          });
          break;
        default:
          this.dialogImageUrl = require("@/" + "img/1.png");
          this.test(res);
      }
      console.log(
        this.dialogImageUrl + "          图片回显路径               "
      );
      if (res.code === 200) {
        // this.uploadList.push({
        //   name: res.data.oldFileName,
        //   url: res.data.fileUrl,
        //   fileId: res.data.id,
        //   urlT: this.dialogImageUrl,
        // });
        this.newfileList.push({
          oldFileName: res.data.oldFileName,
          url: res.data.fileUrl,
          id: res.data.id,
          urlT: this.dialogImageUrl,
        });
        this.formData.backingMaterial += res.data.id + ",";
        // this.uploadedSuccessfully();
      } else {
        this.number--;
        this.$modal.closeLoading();
        this.$modal.msgError(res.msg);
        this.$refs.fileUpload.handleRemove(file);
        this.uploadedSuccessfully();
      }
    },
    // 删除文件
    handleDelete(index) {
      let ossId = this.fileList[index].ossId;
      delOss(ossId);
      this.fileList.splice(index, 1);
      this.$emit("input", this.listToString(this.fileList));
    },
    // 上传结束处理
    uploadedSuccessfully() {
      if (this.number > 0 && this.uploadList.length === this.number) {
        this.fileList = this.fileList.concat(this.uploadList);
        this.uploadList = [];
        this.number = 0;
        this.$emit("input", this.listToString(this.fileList));
        this.$modal.closeLoading();
      }
    },
    // 获取文件名称
    getFileName(name) {
      // 如果是url那么取最后的名字 如果不是直接返回
      if (name.lastIndexOf("/") > -1) {
        return name.slice(name.lastIndexOf("/") + 1);
      } else {
        return name;
      }
    },
    // 对象转成指定字符串分隔
    listToString(list, separator) {
      let strs = "";
      separator = separator || ",";
      for (let i in list) {
        strs += list[i].ossId + separator;
      }
      return strs != "" ? strs.substr(0, strs.length - 1) : "";
    },
    // 移除文件
    removeFile(index, file) {
      // 从 fileList 数组中移除文件
      for (let i = 0; i < this.fileList.length; i++) {
        if (this.fileList[i].fileId == file.fileId) {
          this.fileList.splice(i, 1);
        }
        if (this.newfileList[i].id == file.fileId) {
          this.newfileList.splice(i, 1);
        }
      }
      if (undefined != file.fileId) {
        delFileInfo(file.fileId);
      }

      // 还可以在这里进行删除服务器上对应文件的操作，具体操作取决于您的后端实现
    },
    getSubject(id){
      getSubjectList(id).then(response => {
        console.log(response)
        if (response.code == 200) {
          this.subject = response.msg;
        }
      });
    }
  },
};
</script>

<style lang="scss" scoped>
.el_col {
  display: flex;
  justify-content: space-evenly;
  align-content: center;
}

.card-container {
  height: 80%; /* 设置容器的高度为 100% */
  display: flex;
  flex-direction: column;
}

.card-item {
  flex: 1; /* 平分容器的宽度 */
}

#FormDialog {
  height: 100%;
  display: flex;
  flex-wrap: nowrap;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
}

.dialog-footer1 {
  width: 100%;
  height: 6vh;
  background: #ffffff;
  text-align: center;
  line-height: 6vh;
}

.el-card {
  margin-top: 10px;
  width: 504px;
  height: 200px;
  background-color: #f8faff;
}

.el-select {
  width: 100%;
}

.el-form {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
}

.el-form-item {
  width: 30%;
}

.el-date-editor.el-input,
.el-date-editor.el-input__inner {
  width: 100%;
}

.el-form-item {
  margin-bottom: 22px;
}

.el-table {
  min-height: 50% !important;
}

.always_handerOne {
  height: 80px;
  background-color: #ffffff;
  //border-radius: 14px;
}

.always_handerOne1 {
  height: auto;
  background-color: #ffffff;
  //border-radius: 14px;
  padding: 20px;
}

.always_title {
  font-size: 20px;
  font-weight: bold;
  line-height: 53px;
  margin-left: 30px;
}

.always_title1 {
  font-size: 18px;
  font-weight: bold;
  // line-height: 53px;
  margin-left: 15px;
  position: relative;
}

.always_title1 ::before {
  content: "|";
  flex-shrink: 0;
  width: 4px;
  height: 6%;
  margin-left: 12px;
  // background: #f90;
  color: #f90;
  position: absolute;
  left: -22px;
  margin-bottom: 12px;
}

.always_hander {
  background: url(../../../assets/images/header0.png);
  height: 20px;
  width: 100%;
}

.margin_col {
  margin-bottom: 20px;
}

.el_formContent .el-form-item {
  width: 50%;
}

.imageList {
  display: flex;
}

.demonstration {
  text-align: center;
}

.sel-width {
  width: 90%;
}

.el-header {
  padding: 0px 0px;
}

.el-radio-group {
  display: flex;
  line-height: 1;
  vertical-align: middle;
  font-size: 0;
}

.styleCentre {
  line-height: 2.5;
}

.style-Change {
  padding: 0px 0px;
  background: #ffffff;
}

.el-slider__bar {
  height: 6px;
  background-color: red !important;
  border-top-left-radius: 3px;
  border-bottom-left-radius: 3px;
  position: absolute;
}

.el-tooltip el-slider__button {
  border: solid 2px #49ff7d;
}
</style>
<style scoped>
/deep/ .el-upload {
  width: 100px;
  height: 100px;
  line-height: 100px;
}

/deep/ .el-upload .el-upload-dragger {
  width: 100px;
  height: 100px;
  line-height: 100px;
}

/deep/ .el-upload-list--picture-card .el-upload-list__item {
  width: 100px;
  height: 100px;
  line-height: 100px;
}

/deep/ .upload-file-uploader {
  width: 400%;
  line-height: 0.2;
  height: 100%;
}

/deep/ .el-upload-list__item-thumbnail {
  max-width: 140px; /* 设置图片最大宽度*/
  max-height: 100px; /* 设置图片最大高度 */
  width: auto; /* 宽度自适应*/
  height: auto; /* 高度自适应*/
}

/deep/ .el-radio {
  color: #606266;
  font-weight: 500;
  line-height: 3;
  position: relative;
  cursor: pointer;
  display: inline-block;
  white-space: nowrap;
  outline: none;
  font-size: 14px;
  margin-right: 30px;
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
}

/deep/ .el-slider__runway.show-input {
  margin-right: 330px;
  width: auto;
}

/deep/ .el-slider__input {
  float: right;
  margin-top: 3px;
  width: 130px;
  margin-right: 167px;
}

/deep/ .el-form-item__error {
  color: #ff4949;
  font-size: 12px;
  line-height: 1;
  padding-top: 4px;
  position: absolute;
  top: 100%;
  width: 120px;
  left: 0;
}

/deep/ .el-form-item[data-v-2b0fc66d] {
  margin-bottom: 19px;
}

.form-item {
  width: 100%;
  height: 20vh;
}

.copy-text-box {
  background: #f5f5f5;
  padding: 6px 10px;
  border-radius: 5px;
  height: 15vh;
  font-size: 13px;
  overflow-y: scroll;
  cursor: pointer;
}

.block_file_name {
  line-height: 1.2;
  width: 400%;
}

::v-deep .el-upload-list__item.is-ready,
.el-upload-list__item.is-uploading {
  display: none !important;
}

::v-deep .el-upload-list__item {
  transition: none !important;
}

::v-deep .el-checkbox-button.is-checked .el-checkbox-button__inner {
  background-color: #e8f4ff !important;
  border: 1px solid #409eff !important;
  color: #409eff !important;
  /* background-color: var(--fill-color) !important;
  border: 1px solid var(--fill-border) !important;
  color: #000 !important;   */
}

.ces {
  width: 33.2%;
}

::v-deep .el-checkbox-button__inner {
  width: 100%;
}

::deep .el-form-item--medium {
  width: 30%;
}

::v-deep .el-input-number--medium {
  width: 100%;
}

::v-deep .el-input-number__decrease {
  width: 33.2%;
}

::v-deep .el-input-number__increase {
  width: 33.2%;
}

::v-deep .el-drawer__header {
  height: 35px;
  margin: 20px 30px;
  border-radius: 4px;
  border-left: 5px solid #0169ff;
  background-color: white;
  line-height: 34px;
  padding-left: 18px;
  color: #0169ff;
  background-image: linear-gradient(90deg, #f2f7ff 0%, #ffffff 95%);
  border-radius: 4px;
  font-size: 18px;
  font-weight: 500;
  padding-top: 0px;
}

.text {
  font-size: 14px;
}

.item {
  margin-bottom: 18px;
}

.clearfix:before,
.clearfix:after {
  display: table;
  content: "";
}

.clearfix:after {
  clear: both;
}

.box-card {
  width: 100%;
  height: 20%;
  background-color: #f8faff;
  margin-top: 20px;
}

.cardImg {
  width: 24px;
  height: 24px;
  display: inline-block;
  vertical-align: middle;
}

.titleStyle {
  font-family: PingFangSC-Medium;
  font-size: 16px;
  color: #000000;
  letter-spacing: 0.8px;
  line-height: 20px;
  font-weight: 500;
  margin-left: 8px;
}

::v-deep .el-card__body {
  overflow-y: scroll;
  cursor: pointer;
  padding: 6px 10px;
  height: 70%;
  font-size: 13px;
}

::v-deep .el-button--mini {
  padding: 10px 20px;
}

::v-deep .el-drawer__header {
  min-height: 7% !important;
  height: auto;
}

::v-deep .el-card__header {
  height: 30%;
}

/* .el-checkbox__input.is-checked .el-checkbox__inner,
    .el-checkbox__input.is-indeterminate .el-checkbox__inner {
      border-color: #E6A23C!important;
      background-color: #E6A23C!important;
    }
    .el-checkbox__input.is-focus .el-checkbox__inner{
      border-color:  #E6A23C!important;
    }
    .el-checkbox__input.is-checked+.el-checkbox__label{
    color:#E6A23C!important;
} */
</style>
